package com.jabo.douban.demo.model.usecase;

import com.jabo.douban.demo.domain.repository.HttpRepository;
import com.jabo.douban.demo.model.coreinterface.GetRecommendListTask;
import com.jabo.douban.demo.model.entity.NewsBean;

import io.reactivex.Observable;

/**
 * @anthor JZheng3
 * @Time: 2020/3/2
 */
public class GetRecommendListUseCase {

    private GetRecommendListTask mGetRecommendListTask;

    public GetRecommendListUseCase() {
        mGetRecommendListTask = new HttpRepository();
    }

//    public Observable<BaseBean<RecommendItemBean>> execute(int page, int cid) {
//        return mGetRecommendListTask.getRecommendList(page, cid);
//    }

    public Observable<NewsBean> execute(int page, int num) {
        Observable<NewsBean> newsBeanList = mGetRecommendListTask.getNewsBeanList(page, num);
        return newsBeanList;
    }

}
